﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using EmoneyWeiXinCommon;
using EmoneyWeiXinEntity;
using System.Data;
using System.Data.SqlClient;
namespace EmoneyWeiXinDAL
{
    public class LeftMemuDAL
    {
        public List<leftmemuEntity> getListLiftMemuAll()
        {
            string sql = "select id, title, href, createtime, updatetime, remark, hisid, orderby from leftmemu with(nolock)";
            return SQLHelper.GetDataByColumnsLst<leftmemuEntity>(Config.EmoneyWeiXin, sql, null);
        }

        public List<leftmemuEntity> getListLiftMemuAll(int userid)
        {
            SqlParameter[] parameters = new SqlParameter[] {
            new SqlParameter("@userid",userid)
            };
            List<leftmemuEntity> result = SQLHelper.GetProcedureDataByColumnsLst<leftmemuEntity>(Config.EmoneyWeiXin, "sp_leftmenu_SelectByUserID", parameters);
            return result;
        }
    }
}
